package com.qin.entity;

import java.util.Date;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 书实体类
 * @author BestRiven
 *
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Book implements Comparable<Book>{
	
	private Long id;
	private String image;
	private String title;
	private Long categoryId;
	private String author;
	private Long pressId;
	private String pressName;
	private String introduction;
	private Double price;
	private Double discount;
	private Integer stock;
	private Integer sales;
	private Long click;
	private Integer commentNum;
	private String fileUrl;
	private String details;
	private Boolean status;
	private Date createTime;
	@Override
	public int compareTo(Book o) {
		return sales.compareTo(o.getSales());
	}
	public Book(Long click) {
		super();
		this.click = click;
	}
	
	
}
